<template>
  <div class="ref">
    <h2 ref="title">title</h2>
  </div>
</template>
<script>
import { ref, watchEffect } from 'vue'
export default {
  setup (props) {
    const title = ref(null)
    console.warn(title.value)
    watchEffect(() => {
      console.log(title.value)
    }, {
      flush: 'post'
    })
    return {
      title
    }
  }
}
</script>
<style scoped>
</style>
